home *** CD-ROM | disk | FTP | other *** search
/ Chip 2007 January, February, March & April / Chip-Cover-CD-2007-02.iso / Pakiet bezpieczenstwa / mini Pentoo LiveCD 2006.1 / mpentoo-2006.1.iso / modules / nessus-2.2.8.mo / usr / lib / nessus / plugins / mandrake_MDKSA-2003-032.nasl < prev    next >
Text File  |  2005-01-14  |  6KB  |  207 lines

  1. #
  2. # (C) Tenable Network Security
  3. #
  4. # This plugin text was extracted from Mandrake Linux Security Advisory MDKSA-2003:032
  5. #
  6.  
  7.  
  8. if ( ! defined_func("bn_random") ) exit(0);
  9. if(description)
  10. {
  11.  script_id(14016);
  12.  script_version ("$Revision: 1.2 $");
  13.  script_cve_id("CAN-2003-0085", "CAN-2003-0086");
  14.  
  15.  name["english"] = "MDKSA-2003:032: samba";
  16.  
  17.  script_name(english:name["english"]);
  18.  
  19.  desc["english"] = "
  20. The remote host is missing the patch for the advisory MDKSA-2003:032 (samba).
  21.  
  22.  
  23. The SuSE security team, during an audit of the Samba source code, found a flaw
  24. in the main smbd code which could allow an external attacker to remotely and
  25. anonymously gain root privilege on a system running the Samba server. This flaw
  26. exists in all version of Samba 2.x up to and including 2.2.7a. The Samba team
  27. announced 2.2.8 today, however these updated packages include a patch that
  28. corrects this problem.
  29. MandrakeSoft urges all users to upgrade immediately. If you are unable to apply
  30. the updated packages (perhaps due to unavailability on your preferred mirror),
  31. the following steps can be taken to protect an unpatched system:
  32. The 'hosts allow' and 'hosts deny' options in the smb.conf file can be used to
  33. allow access to your Samba server by only selected hosts; for example:
  34.  
  35. hosts allow = 127.0.0.1 192.168.2.0/24 192.168.3.0/24
  36. hosts deny  = 0.0.0.0/0
  37.  
  38. This will disallow all connections from machines that are not the localhost or
  39. in the 192.168.2 and 192.168.3 private networks. Alternatively, you can tell
  40. Samba to listen to only specific network interfaces by using the 'interfaces'
  41. and 'bind interfaces only' options:
  42.  
  43. interfaces = eth1 lo
  44. bind interfaces only = yes
  45.  
  46. Obviously, use the internal interface for your network and not an external
  47. interface connected to the internet. You may also choose to firewall off some
  48. UDP and TCP ports in addition to the previously mentioned suggestions by
  49. blocking external access to ports 137 and 138 (UDP) and ports 139 and 445 (TCP).
  50. These steps should only be used as a temporary preventative measure and all
  51. users should upgrade as quickly as possible.
  52. Thanks to Sebastian Krahmer and the SuSE security team for performing the audit,
  53. Jeremy Allison for providing the fix, and Andrew Tridgell for providing advice
  54. on how to protect an unpatched Samba system.
  55.  
  56.  
  57. Solution : http://www.mandrakesoft.com/security/advisories?name=MDKSA-2003:032
  58. Risk factor : High";
  59.  
  60.  
  61.  
  62.  script_description(english:desc["english"]);
  63.  
  64.  summary["english"] = "Check for the version of the samba package";
  65.  script_summary(english:summary["english"]);
  66.  
  67.  script_category(ACT_GATHER_INFO);
  68.  
  69.  script_copyright(english:"This script is Copyright (C) 2004 Tenable Network Security");
  70.  family["english"] = "Mandrake Local Security Checks";
  71.  script_family(english:family["english"]);
  72.  
  73.  script_dependencies("ssh_get_info.nasl");
  74.  script_require_keys("Host/Mandrake/rpm-list");
  75.  exit(0);
  76. }
  77.  
  78. include("rpm.inc");
  79. if ( rpm_check( reference:"samba-client-2.2.7a-8.1mdk", release:"MDK8.0", yank:"mdk") )
  80. {
  81.  security_hole(0);
  82.  exit(0);
  83. }
  84. if ( rpm_check( reference:"samba-common-2.2.7a-8.1mdk", release:"MDK8.0", yank:"mdk") )
  85. {
  86.  security_hole(0);
  87.  exit(0);
  88. }
  89. if ( rpm_check( reference:"samba-doc-2.2.7a-8.1mdk", release:"MDK8.0", yank:"mdk") )
  90. {
  91.  security_hole(0);
  92.  exit(0);
  93. }
  94. if ( rpm_check( reference:"samba-server-2.2.7a-8.1mdk", release:"MDK8.0", yank:"mdk") )
  95. {
  96.  security_hole(0);
  97.  exit(0);
  98. }
  99. if ( rpm_check( reference:"samba-swat-2.2.7a-8.1mdk", release:"MDK8.0", yank:"mdk") )
  100. {
  101.  security_hole(0);
  102.  exit(0);
  103. }
  104. if ( rpm_check( reference:"samba-client-2.2.7a-8.1mdk", release:"MDK8.1", yank:"mdk") )
  105. {
  106.  security_hole(0);
  107.  exit(0);
  108. }
  109. if ( rpm_check( reference:"samba-common-2.2.7a-8.1mdk", release:"MDK8.1", yank:"mdk") )
  110. {
  111.  security_hole(0);
  112.  exit(0);
  113. }
  114. if ( rpm_check( reference:"samba-doc-2.2.7a-8.1mdk", release:"MDK8.1", yank:"mdk") )
  115. {
  116.  security_hole(0);
  117.  exit(0);
  118. }
  119. if ( rpm_check( reference:"samba-server-2.2.7a-8.1mdk", release:"MDK8.1", yank:"mdk") )
  120. {
  121.  security_hole(0);
  122.  exit(0);
  123. }
  124. if ( rpm_check( reference:"samba-swat-2.2.7a-8.1mdk", release:"MDK8.1", yank:"mdk") )
  125. {
  126.  security_hole(0);
  127.  exit(0);
  128. }
  129. if ( rpm_check( reference:"nss_wins-2.2.7a-8.1mdk", release:"MDK8.2", yank:"mdk") )
  130. {
  131.  security_hole(0);
  132.  exit(0);
  133. }
  134. if ( rpm_check( reference:"samba-client-2.2.7a-8.1mdk", release:"MDK8.2", yank:"mdk") )
  135. {
  136.  security_hole(0);
  137.  exit(0);
  138. }
  139. if ( rpm_check( reference:"samba-common-2.2.7a-8.1mdk", release:"MDK8.2", yank:"mdk") )
  140. {
  141.  security_hole(0);
  142.  exit(0);
  143. }
  144. if ( rpm_check( reference:"samba-doc-2.2.7a-8.1mdk", release:"MDK8.2", yank:"mdk") )
  145. {
  146.  security_hole(0);
  147.  exit(0);
  148. }
  149. if ( rpm_check( reference:"samba-server-2.2.7a-8.1mdk", release:"MDK8.2", yank:"mdk") )
  150. {
  151.  security_hole(0);
  152.  exit(0);
  153. }
  154. if ( rpm_check( reference:"samba-swat-2.2.7a-8.1mdk", release:"MDK8.2", yank:"mdk") )
  155. {
  156.  security_hole(0);
  157.  exit(0);
  158. }
  159. if ( rpm_check( reference:"samba-winbind-2.2.7a-8.1mdk", release:"MDK8.2", yank:"mdk") )
  160. {
  161.  security_hole(0);
  162.  exit(0);
  163. }
  164. if ( rpm_check( reference:"nss_wins-2.2.7a-8.1mdk", release:"MDK9.0", yank:"mdk") )
  165. {
  166.  security_hole(0);
  167.  exit(0);
  168. }
  169. if ( rpm_check( reference:"samba-client-2.2.7a-8.1mdk", release:"MDK9.0", yank:"mdk") )
  170. {
  171.  security_hole(0);
  172.  exit(0);
  173. }
  174. if ( rpm_check( reference:"samba-common-2.2.7a-8.1mdk", release:"MDK9.0", yank:"mdk") )
  175. {
  176.  security_hole(0);
  177.  exit(0);
  178. }
  179. if ( rpm_check( reference:"samba-doc-2.2.7a-8.1mdk", release:"MDK9.0", yank:"mdk") )
  180. {
  181.  security_hole(0);
  182.  exit(0);
  183. }
  184. if ( rpm_check( reference:"samba-server-2.2.7a-8.1mdk", release:"MDK9.0", yank:"mdk") )
  185. {
  186.  security_hole(0);
  187.  exit(0);
  188. }
  189. if ( rpm_check( reference:"samba-swat-2.2.7a-8.1mdk", release:"MDK9.0", yank:"mdk") )
  190. {
  191.  security_hole(0);
  192.  exit(0);
  193. }
  194. if ( rpm_check( reference:"samba-winbind-2.2.7a-8.1mdk", release:"MDK9.0", yank:"mdk") )
  195. {
  196.  security_hole(0);
  197.  exit(0);
  198. }
  199. if (rpm_exists(rpm:"samba-", release:"MDK8.0")
  200.  || rpm_exists(rpm:"samba-", release:"MDK8.1")
  201.  || rpm_exists(rpm:"samba-", release:"MDK8.2")
  202.  || rpm_exists(rpm:"samba-", release:"MDK9.0") )
  203. {
  204.  set_kb_item(name:"CAN-2003-0085", value:TRUE);
  205.  set_kb_item(name:"CAN-2003-0086", value:TRUE);
  206. }
  207.